Skip to content

🤖 fix: remove duplicate server arg from Coder control plane#40

Merged
ThomasK33 merged 1 commit into
mainfrom
fix/coder-entrypoint-args
Feb 10, 2026
Merged

🤖 fix: remove duplicate server arg from Coder control plane#40
ThomasK33 merged 1 commit into
mainfrom
fix/coder-entrypoint-args

Conversation

@ThomasK33
Copy link
Copy Markdown
Member

Summary
This change fixes Coder control plane pod crashes caused by a duplicated server argument when using the official ghcr.io/coder/coder image.

Background
The reconciler generated pod args beginning with server, while the image entrypoint already executes /opt/coder server. That produced an effective command equivalent to coder server server ..., which failed with unrecognized subcommand "server" and caused CrashLoopBackOff.

Implementation

  • Updated the reconciler's default container args to pass only flags:
    • from: ["server", "--http-address=0.0.0.0:3000"]
    • to: ["--http-address=0.0.0.0:3000"]
  • Kept spec.extraArgs behavior unchanged (still appended).
  • Extended controller reconciliation test coverage to assert generated container args, including appended extraArgs.

Validation

  • make test
  • make build
  • make lint
  • Attempted make verify-vendor (fails currently due external module checksum mismatch for github.com/MirrexOne/unqueryvet@v1.4.0, unrelated to this change)
  • Live cluster verification:
    • Rebuilt and rolled out operator image in KIND
    • Reapplied example CoderControlPlane
    • Confirmed generated deployment args no longer include server
    • Confirmed Coder pod starts and stays running

Risks
Low. The change is tightly scoped to default argument composition for one container in the reconciler. Main regression risk is deployments that depended on the previous incorrect duplicated subcommand behavior; this is unlikely and test coverage now guards expected args.


Generated with mux • Model: openai:gpt-5.3-codex • Thinking: xhigh


Generated with mux • Model: openai:gpt-5.3-codex • Thinking: xhigh • Cost: 98679{COSTS}

The Coder container image already uses an entrypoint of '/opt/coder server'.
Passing "server" in the reconciled Deployment args produced an effective
command of 'coder server server ...', causing control plane pods to crash
with an unrecognized subcommand error.

Update the default args to pass only flags, and keep extraArgs appended.
Extend the controller reconcile test to assert the generated args.

Signed-off-by: Thomas Kosiewski <tk@coder.com>

---

_Generated with [`mux`](https://github.com/coder/mux) • Model: `openai:gpt-5.3-codex` • Thinking: `xhigh`_

---

_Generated with `mux` • Model: `openai:gpt-5.3-codex` • Thinking: `xhigh` • Cost: `bash.00`_

<!-- mux-attribution: model=openai:gpt-5.3-codex thinking=xhigh costs=0.00 -->

Change-Id: I6fbf3726ecce93ef0c389cde239d99d372d11b6d
@ThomasK33
Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector
Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Keep it up!

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@ThomasK33 ThomasK33 added this pull request to the merge queue Feb 10, 2026
@ThomasK33
Copy link
Copy Markdown
Member Author

Merged via the queue into main with commit a26a198 Feb 10, 2026
8 checks passed
@ThomasK33 ThomasK33 deleted the fix/coder-entrypoint-args branch February 10, 2026 19:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant